Benjamin Otte [Sun, 10 Jan 2021 21:37:03 +0000 (21:37 +0000)]
Remove guarantees we do not intend to hold
The fact that we are using gdk-pixbuf for loading files currrently does not mean we will use it going forward.
Also, "anything gdk-pixbuf can load" does not mean anything, because what gdk-pixbuf can load is a compile-time option.
As new_from_resource() will assert() if it cannot load a resource, we must be very sure that people do not use anything but PNG and JPEG for resources and the docs were not clear on that.
Asier Sarasua Garmendia [Sun, 10 Jan 2021 18:00:26 +0000 (18:00 +0000)]
Update Basque translation
Asier Sarasua Garmendia [Sun, 10 Jan 2021 17:59:56 +0000 (17:59 +0000)]
Update Basque translation
Piotr Drąg [Sun, 10 Jan 2021 17:27:55 +0000 (18:27 +0100)]
Update Polish translation
Matthias Clasen [Sat, 9 Jan 2021 05:50:53 +0000 (00:50 -0500)]
4.0.1
Matthias Clasen [Sat, 9 Jan 2021 06:28:11 +0000 (01:28 -0500)]
build: Add a sassc feature
Add an option to disable css rebuilds. This allows
to build GTK from release tarballs (Which are including
the css) without a sassc dependency.
Matthias Clasen [Sat, 9 Jan 2021 03:56:59 +0000 (03:56 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master
Closes #3565
See merge request GNOME/gtk!3061
Matthias Clasen [Sat, 9 Jan 2021 03:20:04 +0000 (22:20 -0500)]
droptarget: Some docs cleanups
Fixes #3565, among other things.
Chun-wei Fan [Wed, 30 Dec 2020 10:14:20 +0000 (18:14 +0800)]
gtkffmediafile.c: Use g_snprintf()
Visual Studio 2013 is just shy of being sufficiently C99-compliant to
build GTK master, as it did not support snprintf() in its CRT
implementation.
Use g_snprintf() to cover for this.
Chun-wei Fan [Wed, 30 Dec 2020 10:13:15 +0000 (18:13 +0800)]
gtk/gtksecurememoryprivate.h: Include glib.h
Some compilers somehow do not have `inline` defined, so include glib.h
to ensure that keyword is defined.`
Matthias Clasen [Wed, 6 Jan 2021 13:12:38 +0000 (08:12 -0500)]
a11y: Avoid __ prefixes for variable names
Seems that msvc does not like that.
Matthias Clasen [Sat, 9 Jan 2021 01:04:22 +0000 (01:04 +0000)]
Merge branch 'nacho/seatdefault' into 'master'
Clean ups in seat default
See merge request GNOME/gtk!3057
Ignacio Casal Quinteiro [Fri, 8 Jan 2021 12:11:56 +0000 (13:11 +0100)]
seatdefault: use g_clear_pointer to unref the tools
Ignacio Casal Quinteiro [Fri, 8 Jan 2021 12:10:56 +0000 (13:10 +0100)]
seatdefault: rename dispose method
Matthias Clasen [Thu, 7 Jan 2021 21:08:46 +0000 (21:08 +0000)]
Merge branch 'wip/nacho/associated-device' into 'master'
gdkdevice: use g_set_object to set the associated device
See merge request GNOME/gtk!3049
Matthias Clasen [Thu, 7 Jan 2021 18:37:28 +0000 (18:37 +0000)]
Merge branch 'mcatanzaro/company-unparent-warning' into 'master'
Add critical if widget has a parent during dispose
See merge request GNOME/gtk!3053
Matthias Clasen [Thu, 7 Jan 2021 18:35:37 +0000 (18:35 +0000)]
Merge branch 'mcatanzaro/unparent' into 'master'
Remove incorrect unparenting guidance from migration guide
See merge request GNOME/gtk!3050
Matthias Clasen [Thu, 7 Jan 2021 18:00:19 +0000 (18:00 +0000)]
Merge branch 'mcatanzaro/gtkbuilder-docs' into 'master'
Improve GtkBuilder documentation
See merge request GNOME/gtk!3055
Matthias Clasen [Thu, 7 Jan 2021 17:55:38 +0000 (17:55 +0000)]
Merge branch 'mcatanzaro/event-controller-porting-guide' into 'master'
Expand event controller API changes section of GTK 4 porting guide
See merge request GNOME/gtk!3054
Michael Catanzaro [Thu, 7 Jan 2021 15:42:08 +0000 (09:42 -0600)]
Remove incorrect unparenting guidance from migration guide
This rule is almost always wrong, and we're having some trouble agreeing
on replacement text. Let's remove the whole paragraph for now, to avoid
confusion.
Benjamin Otte [Thu, 7 Jan 2021 15:49:52 +0000 (09:49 -0600)]
Add critical if widget has a parent during dispose
This is a refcounting bug. Be very verbose about it instead of trying to
call a function that releases a reference to the widget without
references.
Michael Catanzaro [Thu, 7 Jan 2021 17:30:57 +0000 (11:30 -0600)]
gtkbuilder: fix recommendations that no longer make sense in GTK 4
In GTK 3, it was pretty much always better to use
gtk_builder_new_from_whatever() rather than
gtk_builder_add_from_whatever(). But in GTK 4, this is no longer
generally true. Let's add some context on when you want to use one or
the other.
Michael Catanzaro [Thu, 7 Jan 2021 17:18:34 +0000 (11:18 -0600)]
Add section on GtkBuilder API changes to GTK 4 migration guide
Thanks to Benjamin for helping with the language.
Emmanuele Bassi [Thu, 7 Jan 2021 17:17:44 +0000 (17:17 +0000)]
Merge branch 'ebassi/ci-only' into 'master'
ci: Specify `only` for other jobs
See merge request GNOME/gtk!3052
Michael Catanzaro [Thu, 7 Jan 2021 16:53:09 +0000 (10:53 -0600)]
Expand event controller API changes section of GTK 4 porting guide
There is more to say about changes to GtkEventController.
Emmanuele Bassi [Thu, 7 Jan 2021 16:14:04 +0000 (16:14 +0000)]
ci: Only run macOS job on upstream branches
Don't run CI on macOS for forks.
Emmanuele Bassi [Thu, 7 Jan 2021 16:03:10 +0000 (16:03 +0000)]
ci: Specify `only` for other jobs
Otherwise MRs will only run macOS jobs.
Ignacio Casal Quinteiro [Thu, 7 Jan 2021 15:13:39 +0000 (16:13 +0100)]
gdkdevice: use g_set_object to set the associated device
Matthias Clasen [Thu, 7 Jan 2021 13:42:42 +0000 (13:42 +0000)]
Merge branch 'wip/jimmac/flat-buttons' into 'master'
Adwaita: fine tune flat button styling
Closes #3481
See merge request GNOME/gtk!3046
Matthias Clasen [Thu, 7 Jan 2021 13:41:40 +0000 (13:41 +0000)]
Merge branch 'wip/jimmac/hc-switch-border' into 'master'
HC: switch border color
Closes #3460
See merge request GNOME/gtk!3048
Matthias Clasen [Thu, 7 Jan 2021 13:25:11 +0000 (13:25 +0000)]
Merge branch 'wip/nacho/tool-api' into 'master'
seat: improve api to take into account the tool type
See merge request GNOME/gtk!3047
Ignacio Casal Quinteiro [Thu, 7 Jan 2021 11:27:26 +0000 (12:27 +0100)]
seat: improve api to take into account the tool type
Otherwise if we have several tools with the same serial
and hardware id we might match the wrong tool.
Jakub Steiner [Thu, 7 Jan 2021 11:44:53 +0000 (12:44 +0100)]
HC: switch border color
- lighten inverted HC borders while darkening the regular/light variant
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3460
Jakub Steiner [Thu, 7 Jan 2021 11:12:55 +0000 (12:12 +0100)]
Adwaita: fine tune flat button styling
- enough contrast for hover and active, while noticably different in
normal nad headerbar context (and both light and dark variants).
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3481
Matthias Clasen [Wed, 6 Jan 2021 22:13:02 +0000 (22:13 +0000)]
Merge branch 'X11-surface' into 'master'
x11: fix crash on idle compute size without layout
See merge request GNOME/gtk!3031
Matthias Clasen [Wed, 6 Jan 2021 22:10:25 +0000 (22:10 +0000)]
Merge branch 'wip/exalm/headerbar' into 'master'
headerbar: Prepend start window controls instead of appending
See merge request GNOME/gtk!3044
Jordi Mas [Wed, 6 Jan 2021 21:42:44 +0000 (22:42 +0100)]
Update Catalan translation
Alexander Mikhaylenko [Wed, 6 Jan 2021 17:04:55 +0000 (22:04 +0500)]
headerbar: Prepend start window controls instead of appending
Make sure they are always in the correct position.
Matthias Clasen [Wed, 6 Jan 2021 14:52:11 +0000 (14:52 +0000)]
Merge branch 'macos-ci' into 'master'
Macos ci
See merge request GNOME/gtk!3032
Matthias Clasen [Wed, 6 Jan 2021 14:40:36 +0000 (14:40 +0000)]
Merge branch 'wip/jimmac/headerbar-specialcasing' into 'master'
Adwaita: specialcase switches and scales for headerbars
Closes #3504
See merge request GNOME/gtk!3043
Matthias Clasen [Wed, 6 Jan 2021 14:36:02 +0000 (09:36 -0500)]
ci: Limit macos runs
We are building the full stack here, which is pretty expensive,
so only do it for merge requests and master.
Matthias Clasen [Wed, 6 Jan 2021 13:04:24 +0000 (13:04 +0000)]
Merge branch 'wip/jimmac/hc-dim-label' into 'master'
HC: special case .dim-label
Closes #3507
See merge request GNOME/gtk!3042
Jakub Steiner [Wed, 6 Jan 2021 12:02:21 +0000 (13:02 +0100)]
Adwaita: specialcase switches and scales for headerbars
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3504
Jakub Steiner [Wed, 6 Jan 2021 11:46:35 +0000 (12:46 +0100)]
HC: special case .dim-label
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3507
Timm Bäder [Wed, 6 Jan 2021 08:55:57 +0000 (08:55 +0000)]
Merge branch 'dlech-master-patch-65287' into 'master'
doc: fix annotation for GtkCssLocation
See merge request GNOME/gtk!3041
David Lechner [Wed, 6 Jan 2021 04:32:09 +0000 (04:32 +0000)]
doc: fix annotation for GtkCssLocation
GtkCssLocation is a type so it should be prefixed with # rather than @.
Christian Hergert [Wed, 6 Jan 2021 00:20:46 +0000 (16:20 -0800)]
macos: use deprecated NSOnState for older systems
Christian Hergert [Tue, 5 Jan 2021 23:24:41 +0000 (15:24 -0800)]
macos: keep array of pasteboard types
To support Sierra, we need to have access to pasteboard types as a
NSString. Constants are provided in later versions of macOS, but we
can emulate that with an array which is initialized on first access.
Christian Hergert [Wed, 6 Jan 2021 00:01:11 +0000 (16:01 -0800)]
gtk: fix brace initialization for bloom filter
This was breaking CI for macOS and it is a simple enough change to ensure
that just works for the internal buckets.
Christian Hergert [Tue, 5 Jan 2021 21:54:07 +0000 (13:54 -0800)]
macos: supply NSPasteboardType when necessary
On older macOS systems, we might need to provide our own typedef
for the NSPasteboardType. It is just a NSString pointer anyway.
Christian Hergert [Tue, 5 Jan 2021 21:53:22 +0000 (13:53 -0800)]
macos: fix typedef on older macOS
On older systems, we don't have a typedef for gravity. They are a NSString
pointer and we can provide that manually just fine.
Christian Hergert [Tue, 5 Jan 2021 21:52:11 +0000 (13:52 -0800)]
macos: handle point conversion on older macOS
On older systems, the availability of some methods seem to be incorrect
based on Apple documentation. This works around the issue by using
the rect conversion on older systems.
Matthias Clasen [Tue, 5 Jan 2021 21:34:27 +0000 (21:34 +0000)]
Merge branch 'media-caps' into 'master'
media: Be more specific in our caps
See merge request GNOME/gtk!3037
Matthias Clasen [Tue, 5 Jan 2021 19:35:46 +0000 (19:35 +0000)]
Merge branch 'simplify-toolbar' into 'master'
3to4: Remove GtkToolbar::toolbar_style
See merge request GNOME/gtk!3040
Matthias Clasen [Tue, 5 Jan 2021 18:57:47 +0000 (13:57 -0500)]
3to4: Remove GtkToolbar::toolbar_style
The property was removed (with the rest of the widget),
so keeping it around in the ui file makes no sense.
Testcase included.
Matthias Clasen [Tue, 5 Jan 2021 18:41:27 +0000 (18:41 +0000)]
Merge branch 'ebassi/migrating-clipboard' into 'master'
Ebassi/migrating clipboard
See merge request GNOME/gtk!3039
Emmanuele Bassi [Tue, 5 Jan 2021 18:10:59 +0000 (18:10 +0000)]
Merge branch 'dlech-master-patch-06007' into 'master'
docs: fix parameter reference in gtk_bitset_contains()
See merge request GNOME/gtk!3035
David Lechner [Tue, 5 Jan 2021 05:36:19 +0000 (05:36 +0000)]
docs: fix parameter reference in gtk_bitset_contains()
This fixes an error in the doc comments where the first parameter was
referred to as @bitset instead of @self.
Emmanuele Bassi [Tue, 5 Jan 2021 16:51:14 +0000 (16:51 +0000)]
docs: Add migration section for GtkClipboard
A simple copy/paste text example, plus directing people towards the
appropriate GType to replace the old convenience API.
Matthias Clasen [Tue, 5 Jan 2021 16:49:53 +0000 (16:49 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master
See merge request GNOME/gtk!3038
Daniel Șerbănescu [Tue, 5 Jan 2021 16:38:02 +0000 (17:38 +0100)]
Updated the Romanian Translation
Emmanuele Bassi [Tue, 5 Jan 2021 16:19:21 +0000 (16:19 +0000)]
docs: Preformat some symbols
Matthias Clasen [Tue, 5 Jan 2021 16:16:10 +0000 (11:16 -0500)]
gtk-demo: Small a11y fix
Label the entry in the assistant demo.
Matthias Clasen [Tue, 5 Jan 2021 16:15:33 +0000 (11:15 -0500)]
a11y: Only spew help once
Make GTK_A11Y=help only spew once, and avoid a warning
when we do.
Matthias Clasen [Tue, 5 Jan 2021 15:59:59 +0000 (10:59 -0500)]
popup: Mention the popover arrow in the docs
Suggested by Jonas.
Matthias Clasen [Tue, 5 Jan 2021 15:22:09 +0000 (15:22 +0000)]
Merge branch 'no-gl-context' into 'master'
Disable GL support in gstreamer media backend on Windows
See merge request GNOME/gtk!3034
Matthias Clasen [Tue, 5 Jan 2021 15:20:25 +0000 (15:20 +0000)]
Merge branch 'wip/baedert/for-master' into 'master'
Wip/baedert/for master
See merge request GNOME/gtk!3029
Matthias Clasen [Tue, 5 Jan 2021 14:21:01 +0000 (09:21 -0500)]
media: Be more specific in our caps
We can only handle 2D textures, so tell gstreamer
about that.
Matthias Clasen [Tue, 5 Jan 2021 14:26:38 +0000 (14:26 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
some docs tweaks
See merge request GNOME/gtk!3036
Matthias Clasen [Sat, 2 Jan 2021 21:34:34 +0000 (16:34 -0500)]
docs: Cosmetics
Matthias Clasen [Tue, 5 Jan 2021 13:20:36 +0000 (08:20 -0500)]
docs: Flesh out Popup layout docs
We have nice illustrations for this, lets use them.
Yuri Chornoivan [Tue, 5 Jan 2021 08:08:44 +0000 (08:08 +0000)]
Update Ukrainian translation
Timm Bäder [Sun, 3 Jan 2021 21:41:02 +0000 (22:41 +0100)]
csstokenizer: Keep a GString for name parsing around
We only every parse one of those at a time, so keep a GString around for
it. This way we don't have to create a new GString every time we parse
an identifier. Doesn't spare us the strdup though.
Timm Bäder [Sun, 3 Jan 2021 20:53:20 +0000 (21:53 +0100)]
csstokenizer: Add separate init functions for token types
Using a variadic function is just awkward there. Use different init
functions and use them as appropriate; we already know which one to call
everywhere.
Timm Bäder [Sun, 3 Jan 2021 11:33:25 +0000 (12:33 +0100)]
builder: Remove unused typedef
Timm Bäder [Sun, 3 Jan 2021 11:27:32 +0000 (12:27 +0100)]
builder: Remove unused function prototype
Timm Bäder [Sun, 3 Jan 2021 11:23:01 +0000 (12:23 +0100)]
builderparser: Use GPtrArray for stack
Chun-wei Fan [Tue, 5 Jan 2021 06:30:08 +0000 (14:30 +0800)]
gstreamer media backend: Disable OpenGL on Windows
...for at least WGL, since we are not allowed to use wglMakeCurrent(),
which is eventually called by gdk_gl_context_make_current() to share WGL
contexts across different threads, which will cause a crash.
This means, we cannot enable WGL in the gstreamer media backend on
Windows.
Matthias Clasen [Tue, 5 Jan 2021 00:54:37 +0000 (00:54 +0000)]
Merge branch 'matthiasc/gl-media-stream' into 'master'
Use GL in the gstreamer media backend
See merge request GNOME/gtk!3027
Matthias Clasen [Mon, 4 Jan 2021 23:26:29 +0000 (18:26 -0500)]
gtk-demo: Use GtkVideo in the fishbowl
The demo is called 'Video', so we should actually
use a GtkVideo widget. Doing things this way has
the advantage that we get GL support, which wasn't
working with GtkPicture.
Matthias Clasen [Fri, 1 Jan 2021 17:12:35 +0000 (12:12 -0500)]
media: Only force GL if we're using a GL renderer
When we are not using a GL renderer, getting GL textures
is no advantage to us, so don't make gstreamer send its
frames as GL memory in this case.
Matthias Clasen [Fri, 1 Jan 2021 16:31:49 +0000 (11:31 -0500)]
media: Convince gstreamer to deliver GL memory
Use a glsinkbin to make gstreamer deliver GL memory.
Benjamin Otte [Tue, 29 Dec 2020 19:11:51 +0000 (14:11 -0500)]
media: Add support for OpenGL to GtkGstMediaFile
Matthias Clasen [Tue, 29 Dec 2020 20:55:28 +0000 (15:55 -0500)]
video: Realize the media stream before setting a file
This makes it so that we obtain a GL context before
creating the GstSink, so we at least advertise our
ability to handle GL buffer.
Gstreamer still won't send us any.
Matthias Clasen [Mon, 4 Jan 2021 18:14:00 +0000 (18:14 +0000)]
Merge branch 'wip/jimmac/popover-separators' into 'master'
Adwaita: increase cotrast of popover separators
Closes #3535
See merge request GNOME/gtk!3033
Jakub Steiner [Mon, 4 Jan 2021 16:53:40 +0000 (17:53 +0100)]
Adwaita: increase contrast of popover separators
Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3535
Matthias Clasen [Mon, 4 Jan 2021 13:55:08 +0000 (13:55 +0000)]
Merge branch 'window-geometry-info' into 'master'
gtk/window: remove GtkWindowGeometryInfo from public header file
See merge request GNOME/gtk!3028
Aurimas Černius [Mon, 4 Jan 2021 12:09:40 +0000 (14:09 +0200)]
Updated Lithuanian translation
Matthias Clasen [Mon, 4 Jan 2021 02:11:56 +0000 (21:11 -0500)]
Pass coretext=enabled to harfbuzz
When we use harfbuzz as a subproject on OS X,
we (or rather, pango) need coretext support.
Matthias Clasen [Sun, 3 Jan 2021 18:46:34 +0000 (13:46 -0500)]
Fix the cairo build on OS X
Change the subproject to point to a branch that includes
an OS X build fix. Once
https://gitlab.freedesktop.org/cairo/cairo/-/issues/441
is fixed, we should switch back to master.
Matthias Clasen [Sun, 3 Jan 2021 18:23:45 +0000 (13:23 -0500)]
ci: Disable pixman tests on MacOS
The pixman tests fail to build, and I don't have
the stamina to fix all sub-sub-projects, so just
disable the tests.
Matthias Clasen [Sun, 3 Jan 2021 18:13:27 +0000 (13:13 -0500)]
ci: Fix the harfbuzz build on MacOS
We need to force c++11 at the toplevel here, since
meson can't deal with per-project compiler choice.
Matthias Clasen [Sun, 3 Jan 2021 16:59:14 +0000 (11:59 -0500)]
printing: Remove cairo header checks
cc.has_header doesn't work with subprojects, and all this
check does is to make the build fail, so we can just...
let the build fail instead.
Matthias Clasen [Sun, 3 Jan 2021 16:24:26 +0000 (11:24 -0500)]
printing: cairo-pdf is needed
The print backends need cairos pdf support, which is
contingent on zlib, so enable that when using cairo
as a subproject, as we do in ci for MacOS.
Matthias Clasen [Sun, 3 Jan 2021 03:34:52 +0000 (22:34 -0500)]
ci: Add a macos build
Most of this is cribbed from glib.
We don't use COMMON_MESON_FLAGS here, since disabling
-Werror one subproject at a time is too painful for
all the promoted sub-sub-projects. This needs a better
solution in meson.
Since this is a full rebuild of the entire stack, limit
this to master and merge requests.
Rafostar [Sun, 3 Jan 2021 17:02:31 +0000 (18:02 +0100)]
x11: fix crash on idle compute size without layout
On x11 toplevel layout is not created before toplevel
is presented, but GTK tries to update it on idle
which leads to a crash due to accessing property
of undefined object. Treat soon to be created layout
as a layout with default values upon creation (resizable).
Philipp Kiemle [Sun, 3 Jan 2021 13:41:25 +0000 (13:41 +0000)]
Update German translation
Philipp Kiemle [Sun, 3 Jan 2021 13:40:13 +0000 (13:40 +0000)]
Update German translation
Timm Bäder [Sun, 3 Jan 2021 09:17:18 +0000 (10:17 +0100)]
messagedialog: Modernize source file
Move vfunc implementations above class_init, remove unneeded prototypes,
properly indent everything and remove trailing whitespace
Timm Bäder [Sun, 3 Jan 2021 07:45:30 +0000 (08:45 +0100)]
widget: Refactor gtk_widget_class_set_template()
Don't call gbytes_get_data/get_size so often and exit early if the given
bytes is already precompiled.